
package se.sll.service.catalogue.offers.api.model;

import java.util.HashMap;
import java.util.Map;
import javax.annotation.Generated;
import javax.validation.Valid;
import org.codehaus.jackson.annotate.JsonAnyGetter;
import org.codehaus.jackson.annotate.JsonAnySetter;
import org.codehaus.jackson.annotate.JsonIgnore;
import org.codehaus.jackson.annotate.JsonProperty;
import org.codehaus.jackson.annotate.JsonPropertyOrder;
import org.codehaus.jackson.map.annotate.JsonSerialize;


/**
 * A single contract
 * 
 */
@JsonSerialize(include = JsonSerialize.Inclusion.NON_NULL)
@Generated("org.jsonschema2pojo")
@JsonPropertyOrder({
    "id",
    "type",
    "datePeriod"
})
public class Contract {

    /**
     * An Instance Identifier
     * 
     */
    @JsonProperty("id")
    @Valid
    private Id id;
    /**
     * CVType
     * <p>
     * A generic CV Type
     * 
     */
    @JsonProperty("type")
    @Valid
    private Type type;
    /**
     * A Date Period Type
     * 
     */
    @JsonProperty("datePeriod")
    @Valid
    private DatePeriod datePeriod;
    @JsonIgnore
    private Map<String, Object> additionalProperties = new HashMap<String, Object>();

    /**
     * An Instance Identifier
     * 
     * @return
     *     The id
     */
    @JsonProperty("id")
    public Id getId() {
        return id;
    }

    /**
     * An Instance Identifier
     * 
     * @param id
     *     The id
     */
    @JsonProperty("id")
    public void setId(Id id) {
        this.id = id;
    }

    public Contract withId(Id id) {
        this.id = id;
        return this;
    }

    /**
     * CVType
     * <p>
     * A generic CV Type
     * 
     * @return
     *     The type
     */
    @JsonProperty("type")
    public Type getType() {
        return type;
    }

    /**
     * CVType
     * <p>
     * A generic CV Type
     * 
     * @param type
     *     The type
     */
    @JsonProperty("type")
    public void setType(Type type) {
        this.type = type;
    }

    public Contract withType(Type type) {
        this.type = type;
        return this;
    }

    /**
     * A Date Period Type
     * 
     * @return
     *     The datePeriod
     */
    @JsonProperty("datePeriod")
    public DatePeriod getDatePeriod() {
        return datePeriod;
    }

    /**
     * A Date Period Type
     * 
     * @param datePeriod
     *     The datePeriod
     */
    @JsonProperty("datePeriod")
    public void setDatePeriod(DatePeriod datePeriod) {
        this.datePeriod = datePeriod;
    }

    public Contract withDatePeriod(DatePeriod datePeriod) {
        this.datePeriod = datePeriod;
        return this;
    }

    @JsonAnyGetter
    public Map<String, Object> getAdditionalProperties() {
        return this.additionalProperties;
    }

    @JsonAnySetter
    public void setAdditionalProperty(String name, Object value) {
        this.additionalProperties.put(name, value);
    }

    public Contract withAdditionalProperty(String name, Object value) {
        this.additionalProperties.put(name, value);
        return this;
    }

}
